//
//  MPCNavigationBar.h
//  Pods
//
//  Created by 龙鹏飞 on 2017/9/15.
//
//

#import <UIKit/UIKit.h>

@protocol MPCNavigationBarDelegate <NSObject>

- (void)leftBarButtonDidClicked:(UIButton *)button;
- (void)rightBarButtonDidClicked:(UIButton *)button;

@end


@interface MPCNavigationBar : UIView

@property (nonatomic, strong) NSString *title;

@property (nonatomic, strong) UIView *contentView;

@property (nonatomic, strong, readonly) UILabel *titleLabel;
@property (nonatomic, weak) UIView *titleView;
@property (nonatomic, strong) UIImage *backgroundImage;
@property (nonatomic, strong, readonly) UIImageView *backgroundImageView;
@property (nonatomic, strong,readonly) UIButton *leftBarButton;
@property (nonatomic, strong, readonly) UIButton *rightBarButton;
@property (nonatomic, assign) BOOL needBlur;


@property (nonatomic, weak) id<MPCNavigationBarDelegate>delegate;


- (instancetype)initNavigationBarWithViewController:(UIViewController *)viewController
                                      needStatusBar:(BOOL)needStatusBar;

- (instancetype)initNavigationBarWithViewController:(UIViewController *)viewController
                                              title:(NSString *)title
                             leftBarButtonImageName:(NSString *)leftBarButtonImageName
                                      needStatusBar:(BOOL)needStatusBar;

- (instancetype)initNavigationBarWithViewController:(UIViewController *)viewController
                                              title:(NSString *)title
                             leftBarButtonImageName:(NSString *)leftBarButtonImageName
                  leftBarButtonHighlightedImageName:(NSString *)leftBarButtonHighlightedImageName
                                      needStatusBar:(BOOL)needStatusBar;

- (instancetype)initNavigationBarWithViewController:(UIViewController *)viewController
                                              title:(NSString *)title
                             leftBarButtonImageName:(NSString *)leftBarButtonImageName
                  leftBarButtonHighlightedImageName:(NSString *)leftBarButtonHighlightedImageName
                            rightBarButtonImageName:(NSString *)rightBarButtonImageName
                 rightBarButtonHighlightedImageName:(NSString *)rightBarButtonHighlightedImageName
                                      needStatusBar:(BOOL)needStatusBar;


- (void)setBottomLineHidden:(BOOL)hidden;
- (void)setBarAlpha:(CGFloat)alpha;
- (void)setLeftBarButtonImageName:(NSString *)leftBarButtonImageName leftBarButtonHighlightedImageName:(NSString *)leftBarButtonHighlightedImageName;
- (void)setRightBarButtonImageName:(NSString *)rightBarButtonImageName rightBarButtonHighlightedImageName:(NSString *)rightBarButtonHighlightedImageName;

@end
